package com.kuang.controller;

import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

//在templates下的所有页面只能通过controller来跳转
//需要模板引擎的支持
@Controller
public class IndexController {
    @RequestMapping("/test")
    public String tet(Model model) {
        model.addAttribute("msg", "张飒");
        return "test";
    }
}
